<?php

$config = [
    'vars' => array(
        'is_test' 		=> 1,		//测试环境
    ),
    'pool'=>[
        /**
         * mysql
         */
        'pdo_db'		=>[
            'min_size' 	=> 1,
            'connector' => \Woocan\Connector\Pdo::class,
            'host'      => $_ENV['pdo']['host'],
            'port'      => $_ENV['pdo']['port'],
            'user'		=> $_ENV['pdo']['user'],
            'password'	=> $_ENV['pdo']['pass'],
            'db'        => 'wxapi'
        ],

        /**
         * mongo
         */
        'mongo_test' => [
            'min_size' 	=> 1,
            'connector' => \Woocan\Connector\Mongo::class,
            'host'      => $_ENV['mongo']['host'],
            'port'      => $_ENV['mongo']['port'],
            'user'		=> $_ENV['mongo']['user'],
            'password'	=> $_ENV['mongo']['pass'],
            'db'        => 'test',
            'options'   => [
                'authSource'   => 'admin'
            ],
        ],

        /**
         * redis
         */
        'redis_test' => [
            'connector' => \Woocan\Connector\Redis::class,
            'host'      => $_ENV['redis']['host'],
            'port'      => $_ENV['redis']['port'],
            'password'	=> $_ENV['redis']['pass'],
            'db'		=> 0,
        ],
    ],
];

return $config;